<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:aop="http://www.springframework.org/schema/aop"
       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd  http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.0.xsd">

    <bean id="dataSource" class="com.apache.database.datasource.DynamicDataSource" init-method="init">
        <property name="sysEname" value="${sysEname}"/>
        <property name="initialSize" value="10"/>
        <property name="maxActive" value="100"/>
        <property name="minIdle" value="10"/>
        <property name="maxIdle" value="50"/>
    </bean>
    <bean id="manyDataSourceAspect" class="com.apache.database.datasource.DataSourceAspect"/>
    <aop:config>
        <aop:aspect id="manyDataSource" ref="manyDataSourceAspect">
            <aop:pointcut id="txDataSource"
                          expression="execution(* com.apache.api.api.ApiService.*(..))"/>
            <aop:before pointcut-ref="txDataSource" method="before"/>
        </aop:aspect>
    </aop:config>

</beans>